package org.jeecg.modules.monitoring.j_monitoring.mapper;
import java.util.Collection;
import java.util.Date;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.monitoring.j_monitoring.entity.VirtualClusterAddLog;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

/**
 * @Description: 虚拟群集增长记录Mapper
 * @Author: xiaoyq
 * @Date:   2023-11-28
 * @Version: V1.0
 */
public interface VirtualClusterAddLogMapper extends BaseMapper<VirtualClusterAddLog> {
    /**
     * 删除指定条件的虚拟群集日志记录
     * @param recordTime
     * @param clusterId
     * @return
     */
    int deleteByRecordTimeAndClusterId(@Param("recordTime") String recordTime, @Param("clusterId") String clusterId);

    /**
     * 批量添加虚拟群集记录
     * @param virtualClusterAddLogCollection
     * @return
     */
    int insertBatch(@Param("virtualClusterAddLogCollection") Collection<VirtualClusterAddLog> virtualClusterAddLogCollection);

    /**
     * 根据时间查询最新的虚拟群集记录
     * @param time
     * @return
     */
    List<VirtualClusterAddLog> selectLastTimeData(@Param("time") String time);

    /**
     * 根据群集id查询最新的虚拟群集记录
     * @param clusterId
     * @return
     */
    List<VirtualClusterAddLog> selectByClusterId(@Param("clusterId") String clusterId);
}
